package com.tangpei.utils
{
	import flash.utils.Timer;
	
	public class FrameRateTimer extends Timer
	{
		private var _fps:int;
		
		public function FrameRateTimer(fps:int=-1)
		{
			_fps=(fps>-1)?fps:24;
			super(Math.round(1000/_fps),0);
		}
		
		public function get frameRate():int
		{
			return _fps;
		}
	}
}